<?php
/*
Template Name: People
*/
?>
<?php get_header(); ?>
<?php get_sidebar(); ?>
		
	<div id="content">

 
		<?php if (have_posts()) : while (have_posts()) : the_post(); ?>



<h2 class="pagetitle"><?php the_title(); ?> </h2>
<div class="entry"><?php the_content(); ?><?php edit_post_link('edit', '', '&nbsp;&raquo;'); ?></div>
<dl>
<?php
	$childQuery  = $wpdb->get_results("
		SELECT *
		FROM $wpdb->posts
		WHERE post_parent = ".$post->ID."
		AND post_type = 'page'
		ORDER BY menu_order
	", 'OBJECT');

	if ( $childQuery ) :
		foreach ( $childQuery  as $post ) :
			setup_postdata( $post );
			?>

	
<dt><?php the_excerpt(); ?></dt>
<dd>
<span style="font:20px bolder Arial, Helvetica, sans-serif"><?php print '<a href="' . get_permalink( $post->ID ) . '">' . get_the_title( $post->ID ) . '</a>'; ?></span> |<a href="<?php the_permalink() ?>" rel="bookmark" title="Permanent Link to <?php the_title(); ?>"> bio </a><?php edit_post_link('edit', '| ', '&nbsp;&raquo;'); ?>
  </dd>
<br />
		<?php
		endforeach;
	endif;
	?>
    </dl>



	  <h2 class="pagetitle">PEOPLE ACTIVITIES</h2>
			<div class="entry">
   
           
            <br />
			<?php wp_list_authors('show_fullname=1&optioncount=1&hide_empty=0&exclude_admin=0'); ?>
			</div>
		
	<?php endwhile; endif; ?>
	<?php edit_post_link('edit this entry.', '<p>', '</p>'); ?>
    <?php get_footer(); ?> 
	</div>
    

<!--- unuse function
<?php
// display all users with a link to their user page
function show_authors() {
	global $wpdb;
   $users = $wpdb->get_col("SELECT * FROM $wpdb->users ORDER BY user_nicename");
   echo '<dl>';
	foreach($users as $user) {
	   $user = get_userdata($user);
		echo '<dt><a href="' . get_author_posts_url($user->ID, $user->user_nicename) . '">' . $user->display_name . '</a></dt>';
		echo '<dd>' . 'website_<a href="'  . $user->user_url . '">' . $user->user_url . '</dd>';
		echo '<dd>' . 'profile_'  . $user->user_description .'</dd>';
   }
      echo '</dl>';
 } ?>
<?php show_authors(); ?> -->

